package LZ;

import java.util.*;

public class Sz {
    public static void main(String[] args) {
        int[] i = {1,2,3,4,5,6,7};
        int[] i1=i.clone();
        i[3]=0;
        Arrays.sort(i);
        System.out.println(i);
        System.out.println(Arrays.toString(i));
        System.out.println(Arrays.toString(i1));
        ArrayList<Integer> list =new ArrayList<>(100);
        list.add(6);
        list.add(3);
        list.sort(Comparator.naturalOrder());
        System.out.println(list);
        list.add(2);
        Collections.sort(list);
        list.ensureCapacity(100);
        System.out.println(list);
        System.out.println(list.size());
        ArrayList list1 = new ArrayList(1);
        System.out.println(list1);
        Integer[] array = new Integer[]{2, 3, 4};

        List list2 = new ArrayList(Arrays.asList(array));
        System.out.println(list2);
        System.out.println(list.toArray().length);
        Integer[] i3;

    }
}
